Module ParametrosDeEntrada
' em C#
' String[] parametros = Environment.GetCommandLineArgs();
'Console.WriteLine(parametros[0]); //pasta e o programa
'Console.WriteLine(parametros[1]);
'Console.WriteLine(parametros[2]);
'Console.WriteLine(parametros[3]);
'foreach (string arg in args)
' Console.WriteLine("Arg: {0}", arg);
'Console.ReadLine();
Public Function RetornaParametrosEntrada() As String
Dim parametros As String() = Environment.GetCommandLineArgs()
Dim a As String
'Console.WriteLine(parametros(0)) 'p1
'Console.WriteLine(parametros(1)) 'p2
'Console.WriteLine(parametros(2)) 'p3
'Console.WriteLine(parametros(3)) 'p4
'Console.WriteLine("GetCommandLineArgs: {0}", String.Join(", ", parametros))
a = ""
For Each arg As String In parametros
a = a + CStr(arg.Count) + arg
Next
Return a